package de.test.NeutrinoAndroidRemote.UI;

import de.test.NeutrinoAndroidRemote.R;
import de.test.NeutrinoAndroidRemote.Tools.Downloader;
import android.app.Activity;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.widget.TextView;

public class ManualInput extends Activity {

	/** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.manualinput);
        

        final TextView txtResult = (TextView)findViewById(R.id.textView1);
      //TODO: globaler Zugriff auf Prefs_name
		SharedPreferences settings = getSharedPreferences("NeutrinoAndroidRemotePrefs", MODE_PRIVATE);
		String ip = settings.getString("ipAddress", ""); 
        String result = Downloader.Get("http://"+ip+"/control/channellist");
        
        txtResult.setText(result);
    }
}
